package com.aaa.backsystem.service.impl;

import com.aaa.backsystem.entity.Dept;
import com.aaa.backsystem.entity.PetrolStation;
import com.aaa.backsystem.dao.PetrolStationDao;
import com.aaa.backsystem.entity.PetrolStationVo;
import com.aaa.backsystem.service.PetrolStationService;
import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 服务实现类
 * </p>
 *
 * @author gyc
 * @since 2020-07-23
 */
@Service
public class PetrolStationServiceImpl extends ServiceImpl<PetrolStationDao, PetrolStation> implements PetrolStationService {
    @Autowired
    private PetrolStationDao petrolStationDao;

    @Override
    public List<PetrolStation> selectByPetrolStationId(Integer petrolStationId) {
        return petrolStationDao.selectByPetrolStationId(petrolStationId);
    }

    @Override
    public List<Dept> selectDept(Integer deptId) {
        return petrolStationDao.selectDept(deptId);
    }

    @Override
    public List<PetrolStationVo> findAllPetrolStationAndDeptName(Page<PetrolStationVo> pageInfo, Map<String, Object> condition) {
        return petrolStationDao.findAllPetrolStationAndDeptName(pageInfo, condition);
    }

}
